package com.ease.model.type;

import com.ease.common.enums.EnumUtil;
import com.ease.common.enums.NamedEnum;

/**
 * 
 * @author nathanleewei
 * 
 */
public enum DatabaseNullable implements NamedEnum {

	N(false), //
	Y(true); //

	private boolean notNull;

	private DatabaseNullable(boolean notNull) {
		this.notNull = notNull;
	}

	public static DatabaseNullable get(String name) {
		return EnumUtil.get(DatabaseNullable.class, name);
	}

	public String getName() {
		return name();
	}

	/**
	 * @return the value
	 */
	public boolean isNotNull() {
		return notNull;
	}

}
